-
Notifications
You must be signed in to change notification settings - Fork 0
[SSF-105] Combine Standard and Lead Volunteers #78
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
sam-schu
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like it might be possible to update an enum type column by creating a new enum type, switching the column to use the new type, and then deleting the old enum, rather than dropping and re-adding the entire column (which would mess up dummy data). Can you look into this?
Juwang110
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Everything lgtm!
sam-schu
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good!
apps/backend/src/migrations/1764811878152-RemoveMultipleVolunteerTypes.ts
Outdated
Show resolved
Hide resolved
apps/backend/src/migrations/1764811878152-RemoveMultipleVolunteerTypes.ts
Outdated
Show resolved
Hide resolved
sam-schu
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we make it so the migration changes any standard volunteer or lead volunteer in the database into a "volunteer," rather than failing if there are any volunteers in the users table? It shouldn't just update the types, it should also migrate the data to reflect the fact that standard and lead volunteers are now one and the same. (The down migration could change all the volunteers into standard volunteers)
apps/backend/src/migrations/1764811878152-RemoveMultipleVolunteerTypes.ts
Outdated
Show resolved
Hide resolved
apps/backend/src/migrations/1764811878152-RemoveMultipleVolunteerTypes.ts
Outdated
Show resolved
Hide resolved
sam-schu
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
ℹ️ Issue
Closes #105
📝 Description
✔️ Verification
Verified all the endpoints still work:


Made sure volunteer management had the volunteer type removed:
